﻿@model Weapsy.Reporting.Pages.PageAdminModel

@{
    ViewBag.Title = "Create New Page";
}

@section scripts{
    @{ await Html.RenderPartialAsync("_ValidationScriptsPartial"); }
    <script src="~/js/admin/pages/shared.js"></script>
    <script src="~/js/admin/pages/create.js"></script>
}

<div class="page-header">
    <h1>Create New Page</h1>
</div>

<form id="createPageForm" name="createPageForm" data-ajax="true" data-ajax-method="POST" data-ajax-url="/Admin/Page/Save" data-ajax-begin="weapsy.admin.createPage.loading" data-ajax-success="weapsy.admin.pages.redirectToIndex" class="form-horizontal validate-form" role="form">    
    @await Html.PartialAsync("_Page")
    <div class="form-group">
        <div class="col-md-12">
            <button id="save" type="submit" class="btn btn-primary" title="Save">Save</button>
            <a href="@Url.Action("Index", "Page", new { area = "Admin" })" class="btn btn-default" title="Cancel">Cancel</a>
        </div>
    </div>
</form>